package top.suven.base.oauth.service;

import top.suven.base.http.exception.SystemRuntimeException;
import top.suven.base.oauth.dto.request.AuthorizeRequestDto;
import top.suven.base.oauth.dto.request.MaintainRequestDto;
import top.suven.base.oauth.dto.response.AuthorizeResponseDto;
import top.suven.base.oauth.dto.response.MaintainResponseDto;

import java.util.List;

/**
 * @ClassName: AuthorizeService.java
 * @Description: 获取认证服务
 * @Author lixiangling
 * @Date 2018/5/16 14:47
 * @Copyright: (c) 2018 gc by https://www.gc.com.cn/
 * @Version : 1.0.0
 * --------------------------------------------------------
 * modifyer    modifyTime                 comment
 *
 * --------------------------------------------------------
 */
public interface AuthorizeService {
    /**
     * @Title: 向客户端返回access token
     * @Description:
     * @param authorizeRequestDto {@link AuthorizeRequestDto}
     * @return {@link AuthorizeResponseDto}
     * @throw
     *
     * @author lixiangling
     * @date 2018/5/16 11:25
     */
    public AuthorizeResponseDto getAuthCode(AuthorizeRequestDto authorizeRequestDto) throws SystemRuntimeException;

    /**
     * @Title: 检查用户的accessToken是否有效
     * @Description:
     * @param authorizeRequestDto {@link AuthorizeRequestDto}
     * @return {@link Boolean}
     * @throw
     *
     * @author lixiangling
     * @date 2018/5/16 14:21
     */
    public AuthorizeResponseDto checkToken(AuthorizeRequestDto authorizeRequestDto) throws SystemRuntimeException;
    /**
     * @Title:
     * @Description: 根据用户获取token和session
     * @param
     * @return
     * @author liulu
     * @date 2018/6/1 19:07
     */
    public AuthorizeResponseDto getTokenAndSession(AuthorizeRequestDto authorizeRequestDto) throws SystemRuntimeException;
    /**
     * @Title: 获取渠道编码
     * @Description: 
     * @param   
     * @return  
     * @throw 
     * @author lixiangling
     * @date 2018/6/11 18:49
     *  --------------------------------------------------------
     *  modifyer    modifyTime                 comment
     *  
     *  --------------------------------------------------------
     */
    public String getChannelCode(long userId)throws SystemRuntimeException;

    public List<MaintainResponseDto> startMaintainModule(MaintainRequestDto maintainRequestDto)throws SystemRuntimeException;

    public List<MaintainResponseDto> getMaintainModule(MaintainRequestDto maintainRequestDto)throws SystemRuntimeException;
}
